3.1.35 \(\int x (a+b \text {sech}^{-1}(c x))^2 \, dx\) [35]

Optimal. Leaf size=65 \[ -\frac {b \sqrt {\frac {1-c x}{1+c x}} (1+c x) \left (a+b \text {sech}^{-1}(c x)\right )}{c^2}+\frac {1}{2} x^2 \left (a+b \text {sech}^{-1}(c x)\right )^2-\frac {b^2 \log (x)}{c^2} \]

[Out]

1/2*x^2*(a+b*arcsech(c*x))^2-b^2*ln(x)/c^2-b*(c*x+1)*(a+b*arcsech(c*x))*((-c*x+1)/(c*x+1))^(1/2)/c^2

________________________________________________________________________________________

Rubi [A]
time = 0.06, antiderivative size = 65, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.333, Rules used = {6420, 5559, 4269, 3556} \begin {gather*} -\frac {b \sqrt {\frac {1-c x}{c x+1}} (c x+1) \left (a+b \text {sech}^{-1}(c x)\right )}{c^2}+\frac {1}{2} x^2 \left (a+b \text {sech}^{-1}(c x)\right )^2-\frac {b^2 \log (x)}{c^2} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[x*(a + b*ArcSech[c*x])^2,x]

[Out]

-((b*Sqrt[(1 - c*x)/(1 + c*x)]*(1 + c*x)*(a + b*ArcSech[c*x]))/c^2) + (x^2*(a + b*ArcSech[c*x])^2)/2 - (b^2*Lo
g[x])/c^2

Rule 3556

Int[tan[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-Log[RemoveContent[Cos[c + d*x], x]]/d, x] /; FreeQ[{c, d}, x]

Rule 4269

Int[csc[(e_.) + (f_.)*(x_)]^2*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[(-(c + d*x)^m)*(Cot[e + f*x]/f), x
] + Dist[d*(m/f), Int[(c + d*x)^(m - 1)*Cot[e + f*x], x], x] /; FreeQ[{c, d, e, f}, x] && GtQ[m, 0]

Rule 5559

Int[((c_.) + (d_.)*(x_))^(m_.)*Sech[(a_.) + (b_.)*(x_)]^(n_.)*Tanh[(a_.) + (b_.)*(x_)]^(p_.), x_Symbol] :> Sim
p[(-(c + d*x)^m)*(Sech[a + b*x]^n/(b*n)), x] + Dist[d*(m/(b*n)), Int[(c + d*x)^(m - 1)*Sech[a + b*x]^n, x], x]
 /; FreeQ[{a, b, c, d, n}, x] && EqQ[p, 1] && GtQ[m, 0]

Rule 6420

Int[((a_.) + ArcSech[(c_.)*(x_)]*(b_.))^(n_)*(x_)^(m_.), x_Symbol] :> Dist[-(c^(m + 1))^(-1), Subst[Int[(a + b
*x)^n*Sech[x]^(m + 1)*Tanh[x], x], x, ArcSech[c*x]], x] /; FreeQ[{a, b, c}, x] && IntegerQ[n] && IntegerQ[m] &
& (GtQ[n, 0] || LtQ[m, -1])

Rubi steps

\begin {align*} \int x \left (a+b \text {sech}^{-1}(c x)\right )^2 \, dx &=-\frac {\text {Subst}\left (\int (a+b x)^2 \text {sech}^2(x) \tanh (x) \, dx,x,\text {sech}^{-1}(c x)\right )}{c^2}\\ &=\frac {1}{2} x^2 \left (a+b \text {sech}^{-1}(c x)\right )^2-\frac {b \text {Subst}\left (\int (a+b x) \text {sech}^2(x) \, dx,x,\text {sech}^{-1}(c x)\right )}{c^2}\\ &=-\frac {b \sqrt {\frac {1-c x}{1+c x}} (1+c x) \left (a+b \text {sech}^{-1}(c x)\right )}{c^2}+\frac {1}{2} x^2 \left (a+b \text {sech}^{-1}(c x)\right )^2+\frac {b^2 \text {Subst}\left (\int \tanh (x) \, dx,x,\text {sech}^{-1}(c x)\right )}{c^2}\\ &=-\frac {b \sqrt {\frac {1-c x}{1+c x}} (1+c x) \left (a+b \text {sech}^{-1}(c x)\right )}{c^2}+\frac {1}{2} x^2 \left (a+b \text {sech}^{-1}(c x)\right )^2-\frac {b^2 \log (x)}{c^2}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.14, size = 112, normalized size = 1.72 \begin {gather*} \frac {a \left (a c^2 x^2-2 b \sqrt {\frac {1-c x}{1+c x}} (1+c x)\right )-2 b \left (-a c^2 x^2+b \sqrt {\frac {1-c x}{1+c x}} (1+c x)\right ) \text {sech}^{-1}(c x)+b^2 c^2 x^2 \text {sech}^{-1}(c x)^2-2 b^2 \log (c x)}{2 c^2} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[x*(a + b*ArcSech[c*x])^2,x]

[Out]

(a*(a*c^2*x^2 - 2*b*Sqrt[(1 - c*x)/(1 + c*x)]*(1 + c*x)) - 2*b*(-(a*c^2*x^2) + b*Sqrt[(1 - c*x)/(1 + c*x)]*(1
+ c*x))*ArcSech[c*x] + b^2*c^2*x^2*ArcSech[c*x]^2 - 2*b^2*Log[c*x])/(2*c^2)

________________________________________________________________________________________

Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(172\) vs. \(2(61)=122\).
time = 0.44, size = 173, normalized size = 2.66

method result size
derivativedivides \(\frac {\frac {a^{2} c^{2} x^{2}}{2}-b^{2} \mathrm {arcsech}\left (c x \right )+\frac {b^{2} \mathrm {arcsech}\left (c x \right )^{2} c^{2} x^{2}}{2}-b^{2} \mathrm {arcsech}\left (c x \right ) \sqrt {-\frac {c x -1}{c x}}\, \sqrt {\frac {c x +1}{c x}}\, c x +b^{2} \ln \left (1+\left (\frac {1}{c x}+\sqrt {-1+\frac {1}{c x}}\, \sqrt {1+\frac {1}{c x}}\right )^{2}\right )+2 a b \left (\frac {\mathrm {arcsech}\left (c x \right ) c^{2} x^{2}}{2}-\frac {\sqrt {-\frac {c x -1}{c x}}\, \sqrt {\frac {c x +1}{c x}}\, c x}{2}\right )}{c^{2}}\) \(173\)
default \(\frac {\frac {a^{2} c^{2} x^{2}}{2}-b^{2} \mathrm {arcsech}\left (c x \right )+\frac {b^{2} \mathrm {arcsech}\left (c x \right )^{2} c^{2} x^{2}}{2}-b^{2} \mathrm {arcsech}\left (c x \right ) \sqrt {-\frac {c x -1}{c x}}\, \sqrt {\frac {c x +1}{c x}}\, c x +b^{2} \ln \left (1+\left (\frac {1}{c x}+\sqrt {-1+\frac {1}{c x}}\, \sqrt {1+\frac {1}{c x}}\right )^{2}\right )+2 a b \left (\frac {\mathrm {arcsech}\left (c x \right ) c^{2} x^{2}}{2}-\frac {\sqrt {-\frac {c x -1}{c x}}\, \sqrt {\frac {c x +1}{c x}}\, c x}{2}\right )}{c^{2}}\) \(173\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*(a+b*arcsech(c*x))^2,x,method=_RETURNVERBOSE)

[Out]

1/c^2*(1/2*a^2*c^2*x^2-b^2*arcsech(c*x)+1/2*b^2*arcsech(c*x)^2*c^2*x^2-b^2*arcsech(c*x)*(-(c*x-1)/c/x)^(1/2)*(
(c*x+1)/c/x)^(1/2)*c*x+b^2*ln(1+(1/c/x+(-1+1/c/x)^(1/2)*(1+1/c/x)^(1/2))^2)+2*a*b*(1/2*arcsech(c*x)*c^2*x^2-1/
2*(-(c*x-1)/c/x)^(1/2)*((c*x+1)/c/x)^(1/2)*c*x))

________________________________________________________________________________________

Maxima [A]
time = 0.26, size = 84, normalized size = 1.29 \begin {gather*} \frac {1}{2} \, b^{2} x^{2} \operatorname {arsech}\left (c x\right )^{2} + \frac {1}{2} \, a^{2} x^{2} + {\left (x^{2} \operatorname {arsech}\left (c x\right ) - \frac {x \sqrt {\frac {1}{c^{2} x^{2}} - 1}}{c}\right )} a b - {\left (\frac {x \sqrt {\frac {1}{c^{2} x^{2}} - 1} \operatorname {arsech}\left (c x\right )}{c} + \frac {\log \left (x\right )}{c^{2}}\right )} b^{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*arcsech(c*x))^2,x, algorithm="maxima")

[Out]

1/2*b^2*x^2*arcsech(c*x)^2 + 1/2*a^2*x^2 + (x^2*arcsech(c*x) - x*sqrt(1/(c^2*x^2) - 1)/c)*a*b - (x*sqrt(1/(c^2
*x^2) - 1)*arcsech(c*x)/c + log(x)/c^2)*b^2

________________________________________________________________________________________

Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 205 vs. \(2 (61) = 122\).
time = 0.42, size = 205, normalized size = 3.15 \begin {gather*} \frac {b^{2} c^{2} x^{2} \log \left (\frac {c x \sqrt {-\frac {c^{2} x^{2} - 1}{c^{2} x^{2}}} + 1}{c x}\right )^{2} + a^{2} c^{2} x^{2} - 2 \, a b c^{2} \log \left (\frac {c x \sqrt {-\frac {c^{2} x^{2} - 1}{c^{2} x^{2}}} - 1}{x}\right ) - 2 \, a b c x \sqrt {-\frac {c^{2} x^{2} - 1}{c^{2} x^{2}}} - 2 \, b^{2} \log \left (x\right ) + 2 \, {\left (a b c^{2} x^{2} - b^{2} c x \sqrt {-\frac {c^{2} x^{2} - 1}{c^{2} x^{2}}} - a b c^{2}\right )} \log \left (\frac {c x \sqrt {-\frac {c^{2} x^{2} - 1}{c^{2} x^{2}}} + 1}{c x}\right )}{2 \, c^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*arcsech(c*x))^2,x, algorithm="fricas")

[Out]

1/2*(b^2*c^2*x^2*log((c*x*sqrt(-(c^2*x^2 - 1)/(c^2*x^2)) + 1)/(c*x))^2 + a^2*c^2*x^2 - 2*a*b*c^2*log((c*x*sqrt
(-(c^2*x^2 - 1)/(c^2*x^2)) - 1)/x) - 2*a*b*c*x*sqrt(-(c^2*x^2 - 1)/(c^2*x^2)) - 2*b^2*log(x) + 2*(a*b*c^2*x^2
- b^2*c*x*sqrt(-(c^2*x^2 - 1)/(c^2*x^2)) - a*b*c^2)*log((c*x*sqrt(-(c^2*x^2 - 1)/(c^2*x^2)) + 1)/(c*x)))/c^2

________________________________________________________________________________________

Sympy [A]
time = 0.27, size = 99, normalized size = 1.52 \begin {gather*} \begin {cases} \frac {a^{2} x^{2}}{2} + a b x^{2} \operatorname {asech}{\left (c x \right )} - \frac {a b \sqrt {- c^{2} x^{2} + 1}}{c^{2}} + \frac {b^{2} x^{2} \operatorname {asech}^{2}{\left (c x \right )}}{2} - \frac {b^{2} \sqrt {- c^{2} x^{2} + 1} \operatorname {asech}{\left (c x \right )}}{c^{2}} - \frac {b^{2} \log {\left (x \right )}}{c^{2}} & \text {for}\: c \neq 0 \\\frac {x^{2} \left (a + \infty b\right )^{2}}{2} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*asech(c*x))**2,x)

[Out]

Piecewise((a**2*x**2/2 + a*b*x**2*asech(c*x) - a*b*sqrt(-c**2*x**2 + 1)/c**2 + b**2*x**2*asech(c*x)**2/2 - b**
2*sqrt(-c**2*x**2 + 1)*asech(c*x)/c**2 - b**2*log(x)/c**2, Ne(c, 0)), (x**2*(a + oo*b)**2/2, True))

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*arcsech(c*x))^2,x, algorithm="giac")

[Out]

integrate((b*arcsech(c*x) + a)^2*x, x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.02 \begin {gather*} \int x\,{\left (a+b\,\mathrm {acosh}\left (\frac {1}{c\,x}\right )\right )}^2 \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*(a + b*acosh(1/(c*x)))^2,x)

[Out]

int(x*(a + b*acosh(1/(c*x)))^2, x)

________________________________________________________________________________________